<!DOCTYPE html>
<html>
    <head>
        <script src="vue.js"></script>
    </head>
    <body>
        <div id="app">
            <button @click="count += Math.random()">随机数</button>
            <p>自动生成的随机数是: {{count}}</p>
        </div>
        <script>
            var vm = new Vue({
                el:'#app',
                data: {
                    count:0
                }
            })
        </script>
    </body>
</html>